import { navigationTo, useParams } from "@sker/sdk";
import { renderAdminPage } from "@sker/ui";
import React from "react";

export const DesignPage: React.FC<{}> = ({ }) => {
    const { params, onChange } = useParams<any>({})
    return <div className="flex relative">
        <div className="flex flex-col w-200px px-24px pt-24px bg-#323764 c-#fff" style={{ minWidth: '200px' }}>
            <div className="flex ">
                <div className="flex-1 relative py-12px split flex center">PC端</div>
                <div className="flex-1 relative py-12px flex center">移动端</div>
            </div>
            <div className="flex flex-col py-24px">
                <div className="cursor-pointer pl-12px card" onClick={async e => {
                    const page = await navigationTo('fj/yd/web/yuding')
                    onChange({ page })
                }}>预定首页</div>
            </div>
        </div>
        <div className="flex flex-1 px-24px" style={{ height: `calc(100vh - 56px)`, overflow: `auto` }}>
            {params.page}
        </div>
    </div>
}

renderAdminPage(DesignPage, 'imeepos/workspace/web/design')

